package com.xh.bussiness.tiku.model;

import java.util.List;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.xh.core.model.SuperEntity;

import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 教材版本
 * </p>
 *
 * @author daiwei
 * @since 2019-02-25
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName("tiku_book_version")
public class BookVersion extends SuperEntity {

    private static final long serialVersionUID = 1L;

    /**
	 * 名称
	 */
	private String name;
	/**
	 * 描述
	 */
	private String description;
	/**
	 * 学科
	 */
	private String subject;
	/**
	 * 序号
	 */
	private Integer sortIndex;

	/**
	 * 年级id
	 */
	private String gradeId;
	/**
	 * 年级名次
	 */
	private String gradeName;
	/**
	 * 学期id
	 */
	private String termId;
	/**
	 * 学期名称
	 */
	private String termName;
	/**
	 * 版本id
	 */
	private String versionId;
	/**
	 * 版本名称
	 */
	private String versionName;
	/**
	 * 章节
	 */
	@TableField(exist=false)
	private List<BookChapter> childs;
	
	public BookVersion() {
		super();
	}
	
	public BookVersion(String id, String name, String description,String subject, Integer sortIndex,String gradeId, String gradeName, String termId, String termName,
			String versionId, String versionName, List<BookChapter> chapters) {
		super();
		super.setId(id);
		this.name = name;
		this.description = description;
		this.subject = subject;
		this.sortIndex = sortIndex;
		this.gradeId = gradeId;
		this.gradeName = gradeName;
		this.termId = termId;
		this.termName = termName;
		this.versionId = versionId;
		this.versionName = versionName;
		this.childs = chapters;
	}

}
